package com.hzh.cusviewdemo.Util;

import com.tencent.mmkv.MMKV;

public class MmkvUtlis {
    private final MMKV Mmmkv;
    public static MmkvUtlis mInstance;

    public static MmkvUtlis getInstance() {
        if (mInstance == null) {
            mInstance = new MmkvUtlis();
        }
        return mInstance;
    }

    public MmkvUtlis() {
        Mmmkv = MMKV.defaultMMKV();
    }

    public void setValues(String k, String v) {
        Mmmkv.encode(k, v);
    }

    public String getValues(String k) {
        return Mmmkv.decodeString(k);
    }

    public void removeValues(String k) {
        Mmmkv.remove(k);
    }

}
